<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<link href="https://cdn.staticfile.org/twitter-bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">
				<script src="https://cdn.staticfile.org/jquery/2.1.1/jquery.min.js"></script>
				<script src="https://cdn.staticfile.org/twitter-bootstrap/3.3.7/js/bootstrap.min.js"></script>
				<script >
					function calc(){
						sal = $("#salary").val();
						salnum = parseInt(sal);
						ylgr = salnum * 0.08;
						ylgs = salnum*0.2;
						$("#ylgr").text(ylgr);
						$("#ylgs").text(ylgs);
						}
				</script>
	</head>
	<body>
		<div class="container text-center">
			<h1>个人社保计算</h1>
			<table class="table table-bordered">
				
				<tr><td class="text-center">工资</td>
				<td colspan="3">
					<input id="salary" placeholder="请输入工资" class="form-control"  />
				</td>
				<td><button  onclick="calc()" class = "btn-danger btn-block">计算</button></td></tr>
				<tr class="text-center bg-primary"><td>险种</td>
					<td>个人%</td>
					<td>个人</td>
					<td>公司%</td>
					<td>公司</td>
				<tr class="text-center">
				<td>养老</td>
				<td>8%</td>
				<td id="ylgr"></td>
				<td>20%</td>
				<td id="ylgs"></td>
				<tr>
					<tr class="text-center">
					<td>医疗</td>
					<td>2%</td>
					<td id="ylgr">160</td>
					<td>6%</td>
					<td id ="ylgs">480</td>
					<tr>
						
						<tr class="text-center">
						<td>失业</td>
						<td>0.5%</td>
						<td id ="sygr">40</td>
						<td>1.5%</td>
						<td id="sygs">120</td>
						<tr>
							
							<tr class="text-center">
							<td>工伤</td>
							<td></td>
							<td id ="gsgr"></td>
							<td>0.5</td>
							<td id = "gsgr">40</td>
							<tr>
								
								<tr class="text-center">
								<td>生育</td>
								<td></td>
								<td id = "sygr"></td>
								<td>0.8</td>
								<td id = "sygs">64</td>
								<tr>
									<tr class="text-center">
									<td>公积金</td>
									<td>12%</td>
									<td id="gjjgr">960</td>
									<td></td>
									<td id ="gjjgs">960</td>
									<tr>
										<tr class="text-center">
										<td>合计</td>
										<td>个人合计</td>
										<td>1800</td>
										<td>公司合计</td>
										<td>3046</td>
										<tr class="text-center">
											<tr>
												<td colspan="5">总计
										</td>
											</tr>
					
				</tr>
			</table>
			开发者：xxxaaaaaaa
		</div>
	</body>
</html>
